package decoration.v1;

public class DecorationTest {
    public static void main(String[] args) {
        Pancakes pancakes = new Pancakes();
        System.out.println("一个煎饼"+pancakes.getPrice()+"元");

        PancakesWithEgg pancakesWithEgg = new PancakesWithEgg();
        System.out.println("加一个鸡蛋加2元，价格是"+pancakesWithEgg.getPrice()+"元");

        PancakesWithHamAndEgg pancakesWithHamAndEgg = new PancakesWithHamAndEgg();
        System.out.println("加一个鸡蛋和火腿，价格是"+pancakesWithHamAndEgg.getPrice()+"元");
    }
}
